<template>
	<view>
		<view>
			<view class="bottomBox">
			<view  v-if="isAudit == 0 || isAudit === false" class="tabbarItem" @click="handleVisibleFun('enable')">
				<u-icon class="tabImg" size="40" height="40" name="bag"></u-icon>
				<view>启用</view>
			</view>
			<view  v-if="isAudit == 1 || isAudit === true" class="tabbarItem" @click="handleVisibleFun('disable')">
				<u-icon class="tabImg" size="40" height="40" name="bag"></u-icon>
				<view>禁用</view>
			</view>

			<view class="tabbarItem" @click="bianjiFun">
				<u-icon class="tabImg" size="40" height="40" name="edit-pen-fill"></u-icon>
				<view>编辑</view>
			</view>
				<view class="tabbarItem" @click="deleteDataFun">
					<u-icon class="tabImg" size="40" height="40" name="trash"></u-icon>
					<view>删除</view>
				</view>
			</view>
		</view>
		<u-action-sheet :list="sList" v-model="moreIsShow" @click="sheetClickFun"></u-action-sheet>
		<u-select v-model="allotShow" mode="single-column" confirm-text="确认分配" cancel-text="取消分配" :list="userList"
			@confirm="allotConfirmFun" value-name="id" label-name="realname"></u-select>
	</view>
</template>
<script>
	import {apiCustomer} from '@/api/crm.js'
	import {apiSysUser} from '@/api/admin.js'
	export default {
		name: "bottomBoxFin",
		props: {
			item: {
				type: Object,
				default: () => {}
			},
			sheetList: {
				type: Array,
				default: () => []
			},
			addSheetList: {
				type: Array,
				default: () => []
			},
			isGhc: {
				type: Boolean,
				default: false
			},
			isKh: {
				type: Boolean,
				default: false
			},
		isAudit: {
			type: [Boolean, Number],
			default: false
		}
		},
		data() {
			return {
				moreIsShow: false,
				sList: [],
				sheetType: '',
				allotShow: false,
				userList: []
			};
		},
		methods: {
			
			//详细页在跟进
			genjinFun: function() {
				this.$emit('pageGenjinFun')
			},
			
			//详细页中删除
			deleteDataFun: function() {
				this.$emit('pageDeleteShowFun')
			},

			//详细页中的编辑
			bianjiFun: function() {
				this.$emit('pageBianjiFun')
			},

			//点击审核
			handleVisibleFun: function(str) {
				this.$emit('pagehandleVisibleFun',str)
			},
	
		}
	}
</script>

<style>
	.bottomBox {
		width: 100%;
		height: 55px;
		display: flex;
		align-items: center;
		justify-content: space-around;
		background-color: #FFFFFF;
		border-top: 1rpx solid #DDDDDD;
		font-size: 14px;
	}

	.tabbarItem {
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		height: 100%;
		padding: 0 36rpx;
	}

	.tabbarItem:active {
		background-color: #EEEEEE;
	}

	.tabbarItem>.tabImg {
		margin-bottom: 8rpx;
	}
</style>